VXLAN与flat网络共存测试模型 | 您所在的位置:网站首页 › linux em1配置 › VXLAN与flat网络共存测试模型 |
受限于实体网络以及主机网卡,利用em2接口作为vm的流量接口,该接口所在网络以vxlan 网络运行,同时compute主机的另一个接口em1配置为支持openstack flat网络,这样可以在openstack内部起一个flat类型网络,该网络还可以顺便作为L3 agent的external 网络。 flat 网络是openstack中非vlan方式的可以与外部物理网络直接通的一种provider网络。 compute节点添加一个br-ex接口,将地址分配到该br-ex接口上 123456789101112131415161718192021222324252627282930313233343536 root@compute:/var/log/upstart# cat /etc/network/interfaces# This file describes the network interfaces available on your system# and how to activate them. For more information, see interfaces(5). # The loopback network interfaceauto loiface lo inet loopback # The primary network interfaceauto em1iface em1 inet manualup ifconfig $IFACE 0.0.0.0 upup ip link set $IFACE promisc ondown ip link set $IFACE promisc offdown ifconfig $IFACE down # Used for openstack flat and hypervisor mgmtauto br-exiface br-ex inet static address 9.9.9.6 netmask 255.255.255.0 network 9.9.9.0 broadcast 9.9.9.255 gateway 9.9.9.253 # dns-* options are implemented by the resolvconf package, if installed dns-nameservers 8.8.8.8 auto em2iface em2 inet static address 10.1.1.6 netmask 255.255.255.0 network 10.1.1.0 broadcast 10.1.1.255然后添加 br-ex 桥以及将em1接口加入br-ex桥 ovs-vsctl add-br br-ex ovs-vsctl add-port br-ex em1 reboot 机器 network节点以及计算节点ml2文件配置如下: 123456789101112131415161718192021222324252627282930 root@compute:/var/log/upstart# egrep -v "^$|^#" /etc/neutron/plugins/ml2/ml2_conf.ini[ml2]type_drivers = flat,vxlan,vlan,gretenant_network_types = vxlan,vlanmechanism_drivers = openvswitch[ml2_type_flat]flat_networks = phyflat9[ml2_type_vlan][ml2_type_gre]tunnel_id_ranges = 1:1000[ml2_type_vxlan]vni_ranges = 65537:69999[ovs]local_ip = 10.1.1.6tunnel_type = vxlantunnel_bridge = br-tunintegration_bridge = br-inttunnel_id_ranges = 65537:69999tenant_network_type = vxlanenable_tunneling = truenetwork_vlan_ranges = phyflat9bridge_mappings = phyflat9:br-ex[agent]root_helper = sudo neutron-rootwrap /etc/neutron/rootwrap.conftunnel_types = vxlanvxlan_udp_port = 4789l2_population = False[securitygroup]enable_security_group = Truefirewall_driver = neutron.agent.linux.iptables_firewall.OVSHybridIptablesFirewallDriver配置完毕后,可以创建一个flat 网络 keystone tenant-list neutron net-create --tenant-id 496355a769d94241afbbdc76adbe1fb5 sharedflat9 --shared --router:external=True --provider:network_type flat --provider:physical_network phyflat9 neutron net-create --tenant-id 496355a769d94241afbbdc76adbe1fb5 sharedflat9 --shared --provider:network_type flat --provider:physical_network phyflat9 可以将该网络分配给L3 agent router作为external网络使用,这样L3 agent就可以通过该网络连接到internet处的F5设备。 相关文章 openstack heat模板之配置基本LB到F5 BIGIP Mitaka Openstack 排错备忘 Openstack Mitaka 在Centos7上的自动化安装 Neutron/DVR L2 Agent 观察openstack中VXLAN的flows(Icehouse,ubuntu14.04) |
CopyRight 2018-2019 实验室设备网 版权所有 |